<div style="background:url(/ccds/img/frontend/headbar-bg.gif) repeat-x;">
	<div style="float:left;padding-top:4px;padding-left:10px;"><strong>{$obj.obj_name_name|stripslashes|truncate:80:"..."}</strong></div>
	<div style="float: right;"><a href="javascript:void(0);" onclick="CMS_close();"><img src="/ccds/img/frontend/bt-close.gif" alt="schliessen" border="0" /></a></div>
	<div style="clear:both;"></div>
</div>


<div style="position:relative;padding:8px;">
	<div class="contentbox_box">
		<div class="contentbox_headbar">Laufzeit</div>
		<div style="margin: 5px;" id="DivContentEditorExpire">
			<form name="content_expire_form" id="content_expire_form" onsubmit="return false;">
				<input type="hidden" name="obj_id" id="obj_id" value="{$obj.obj_id}"  />
				<div style="float:left;width:60px;">
					aktivieren
				</div>
				<div style="float:left;">
					<input type="checkbox" name="obj_expire" id="obj_expire"  value="1" {if $obj.obj_expire ==1}checked="checked"{/if} />
				</div>
				<br style="clear:both;" />
				
				<div style="float:left;width:60px;">
					Start
				</div>
				<div style="float:left;">
					<select name="obj_expire_start_day" id="obj_expire_start_day" size="1">
						{foreach name="valueloop" from=$obj.days item=value}
							<option value="{$value}" {if $value== $obj.obj_expire_start|date_format:"%d"}selected="selected"{/if}>{$value}</option>
						{/foreach}		
					</select>	
					<select name="obj_expire_start_month" id="obj_expire_start_month" size="1">
						{foreach name="valueloop" from=$obj.months item=value}
							<option value="{$value}" {if $value== $obj.obj_expire_start|date_format:"%m"}selected="selected"{/if}>{$value}</option>
						{/foreach}		
					</select>	
					<input type="text" name="obj_expire_start_year" id="obj_expire_start_year" value="{$obj.obj_expire_start|date_format:"%Y"}" style="width: 50px;" />
					HH:mm
					<input type="text" name="obj_expire_start_hour" id="obj_expire_start_hour" value="{$obj.obj_expire_start|date_format:"%H"}" style="width: 20px;" />:
					<input type="text" name="obj_expire_start_minute" id="obj_expire_start_minute" value="{$obj.obj_expire_start|date_format:"%M"}" style="width: 20px;" />
				</div>
				<br style="clear:both;" />
				<div style="float:left;width:60px;">
					Ende
				</div>			
				<div style="float:left;">
					<select name="obj_expire_end_day" id="obj_expire_end_day" size="1">
						{foreach name="valueloop" from=$obj.days item=value}
							<option value="{$value}" {if $value== $obj.obj_expire_end|date_format:"%d"}selected="selected"{/if}>{$value}</option>
						{/foreach}		
					</select>	
					<select name="obj_expire_end_month" id="obj_expire_end_month" size="1">
						{foreach name="valueloop" from=$obj.months item=value}
							<option value="{$value}" {if $value== $obj.obj_expire_end|date_format:"%m"}selected="selected"{/if}>{$value}</option>
						{/foreach}		
					</select>	
					<input type="text" name="obj_expire_end_year" id="obj_expire_end_year" value="{$obj.obj_expire_end|date_format:"%Y"}" style="width: 50px;" />
					HH:mm
					<input type="text" name="obj_expire_end_hour" id="obj_expire_end_hour" value="{$obj.obj_expire_end|date_format:"%H"}" style="width: 20px;" />:
					<input type="text" name="obj_expire_end_minute" id="obj_expire_end_minute" value="{$obj.obj_expire_end|date_format:"%M"}" style="width: 20px;" />
				</div>		
				<br style="clear:both;" />

				<div style="float:left;width:20px;">
					<input type="checkbox" name="obj_expire_del" id="obj_expire_del" value="1" {if $obj.obj_expire_del ==1}checked="checked"{/if} />
				</div>
				<div style="float:left;">nach ablauf löschen</div>
				<br style="clear:both;" />		
				<input type="checkbox" name="apply_linked" value="1" id="apply_linked" checked="checked"	> Diese Einstellungen auf verlinkte Objekte übertragen.<br />
				<br />
				<input type="submit" class="submitbtn" value="speichen" onclick="{literal}xajax.request({xjxfun:'FrontEndExpireSave'},{parameters:[xajax.getFormValues('content_expire_form')]});{/literal}" />
			</form>
		</div>
	</div>
	<br />
	<hr style="width:100%" color="#CCCCCC" noshade="noshade" size=1 />
	<br />

	{if is_array($aFormFields) }
		<form name="form_parameter_edit" id="form_parameter_edit">
			<input type="hidden" name="obj_id" value="{$obj.obj_id}" />
			{foreach name="formfieldloop" item=field from=$aFormFields}
				{if file_exists("`$CMS_TPL_DIR`forms/`$field.formtype`.tpl")}
					{include file="`$CMS_TPL_DIR`forms/`$field.formtype`.tpl" content=$field}
				{else}
					<strong>MISSING</strong> {$field.formtype}<br />
				{/if}
				<hr style="width:100%" color="#CCCCCC" noshade="noshade" size=1 />
			{/foreach}
	
			{if $obj.permissions.modify == 1}
				<div class="divFormFieldLabel">&nbsp;</div>
				<div class="divFormFieldInput"><input type="button" name="submitbtn" value="speichern" class="submitbtn" onclick="{literal}tinyMCE.triggerSave(false, false);xajax.request({xjxfun:'FrontEndParameterSave'},{parameters:[xajax.getFormValues('form_parameter_edit')]});{/literal}"/></div>
				<br style="clear:both;" />

			{else}
				Sie haben nicht Berechtigungen diesen Eintrag zu bearbeiten.
			{/if}
		</form>
	{else}
		Dieses Objekt enthält keine Parameter
	{/if}

</div>
<div style="background:url(/ccds/img/frontend/headbar-bg.gif) repeat-x;">
	<div style="float:left;padding-top:4px;padding-left:10px;"><strong>{$obj.obj_name_name|stripslashes|truncate:80:"..."}</strong></div>
	<div style="float: right;"><a href="javascript:void(0);" onclick="CMS_close();"><img src="/ccds/img/frontend/bt-close.gif" alt="schliessen" border="0" /></a></div>
	<div style="clear:both;"></div>
</div>
